package com.peas.platform.module.icims.contract.initial.adapter.repository.po;

import java.math.*;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.peas.platform.common.core.annotation.Comment;
import com.peas.platform.framework.mybatisplus.po.BasePo;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.apache.ibatis.type.JdbcType;
import javax.validation.constraints.*;

// 初始合同执行-补充协议
@Data
@EqualsAndHashCode(callSuper = false)
@TableName(value = "`tbl_contract_initial_supplemental`")
public class ContractInitialSupplementalPo extends BasePo {

    // 合同ID
    // 【初始合同表】
    @Comment(value = "合同ID")
    @NotNull(message = "合同ID不能为空")
    @TableField(value = "`contract_initial_id`", jdbcType = JdbcType.BIGINT)
    private Long contractInitialId;

    // 批次号
    @Comment(value = "批次号")
    @Size(max = 20, message = "批次号不能超过20个字符")
    @TableField(value = "`batch`", jdbcType = JdbcType.VARCHAR)
    private String batch;

    // 补充协议经办人
    // 【用户表】
    @Comment(value = "补充协议经办人")
    @TableField(value = "`supplemental_user_id`", jdbcType = JdbcType.BIGINT)
    private Long supplementalUserId;

    // 补充协议经办部门
    // 【组织架构表】
    @Comment(value = "补充协议经办部门")
    @TableField(value = "`supplemental_department_id`", jdbcType = JdbcType.BIGINT)
    private Long supplementalDepartmentId;

    // 补充协议编号
    @Comment(value = "补充协议编号")
    @NotBlank(message = "补充协议编号不能为空")
    @Size(max = 100, message = "补充协议编号不能超过100个字符")
    @TableField(value = "`supplemental_contract_no`", jdbcType = JdbcType.VARCHAR)
    private String supplementalContractNo;

    // 补充协议名称
    @Comment(value = "补充协议名称")
    @Size(max = 200, message = "补充协议名称不能超过200个字符")
    @TableField(value = "`supplemental_contract_name`", jdbcType = JdbcType.VARCHAR)
    private String supplementalContractName;

    // 补充协议增加金额
    @Comment(value = "补充协议增加金额")
    @TableField(value = "`supplemental_amount`", jdbcType = JdbcType.DECIMAL)
    private BigDecimal supplementalAmount;

    // 补充原因
    @Comment(value = "补充原因")
    @Size(max = 1000, message = "补充原因不能超过1000个字符")
    @TableField(value = "`supplemental_reason`", jdbcType = JdbcType.VARCHAR)
    private String supplementalReason;

    // 补充协议内容
    @Comment(value = "补充协议内容")
    @TableField(value = "`supplemental_content`", jdbcType = JdbcType.CLOB)
    private String supplementalContent;

    // 补充协议状态
    // 枚举取值:ContractInitialSupplementalState
    @Comment(value = "补充协议状态", enumType = "ContractInitialSupplementalState")
    @Size(max = 20, message = "补充协议状态不能超过20个字符")
    @TableField(value = "`state`", jdbcType = JdbcType.VARCHAR)
    private String state;

}
